package com.com.knowledgepaymentmanagementsystem.service.marketing.impl;

import com.com.knowledgepaymentmanagementsystem.mapper.marketing.CashbackMapper;
import com.com.knowledgepaymentmanagementsystem.pojo.marketing.Cashback;
import com.com.knowledgepaymentmanagementsystem.service.marketing.CashbackService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @Author 冯炜轩
 * @Date 2025/9/23 15:58
 * @Version 1.0
 * @Description:
 */
@Service
public class CashbackServiceImpl implements CashbackService {
    @Autowired
    private CashbackMapper cashbackMapper;

    @Override
    public List<Cashback> getCashback(Cashback cashback) {
        return cashbackMapper.getCashback(cashback);
    }

    @Override
    public Object insertCashback(Cashback cashback) {
        return  cashbackMapper.insert(cashback);
    }

    @Override
    public void updateCashback(Cashback cashback) {
        cashbackMapper.updateById(cashback);
    }

    @Override
    public void deleteCashback(Integer id) {
        cashbackMapper.deleteById(id);
    }
}
